package cn.article.entity;

import cn.easier.club.base.annotation.Convert;



public class ArticleQualityConverter implements Convert<String, ArticleQuality>{

	@Override
	public ArticleQuality convert(String source) {
		if(ArticleQuality.GOOD_PRODUCTS.getDescription().equals(source)){
			return ArticleQuality.GOOD_PRODUCTS;
		}else if(ArticleQuality.INFERIOR.getDescription().equals(source)){
			return ArticleQuality.INFERIOR;
		}else{
			return ArticleQuality.DEFECTIVE_PRODUCTS;
		}
	}

}
